MacroPdfBarcodeShape HatchPattern
Gets or sets the hatch pattern of the barcode shape.
public BarcodeHatchPattern HatchPattern {get;Set} |
Return value
BarcodeHatchPattern | Object representing the hatch pattern |
Example
Copy
scanDocument = scanDeviceManager.CreateScanDocument(GetselectedDeviceUniqueName(), DistanceUnit.Millimeters, false);
if (scanDocument != null)
{
VectorImage vectorImage = scanDocument.CreateVectorImage("image1", DistanceUnit.Millimeters);
vectorImage.SetMarkSpeed(1000);
vectorImage.SetJumpSpeed(2000);
vectorImage.SetJumpDelay(100);
vectorImage.SetMarkDelay(100);
//Set Laser Delays
vectorImage.SetLaserOnDelay(10);
vectorImage.SetLaserOffDelay(10);
MacroPdfBarcodeShape mpBarcode = new MacroPdfBarcodeShape();
mpBarcode.Angle = 0;
mpBarcode.AutoExpand = true;
mpBarcode.CompactMode = MacroPdf417CompactionMode.ByteMode;
mpBarcode.ErrorCorrectionLevel = MacroPdf417ErrorCorrectionLevel.Level1;
mpBarcode.FlipHorizontally = false;
mpBarcode.FlipVertically = false;
mpBarcode.Height = 5;
mpBarcode.Width = 8;
mpBarcode.InvertImage = false;
mpBarcode.Location = new Point3D(0, 0, 0);
mpBarcode.MarkingOrder = MarkingOrder.HatchBeforeOutline;
mpBarcode.QuietZone = false;
mpBarcode.Text = "SMAPI VER 4";
mpBarcode.NumberOfColumns = 8;
mpBarcode.NumberOfRows = 6;
mpBarcode.HatchingDirection = BarcodeScanDirection.TopToBottom;
mpBarcode.HatchLineDirection = BarcodeScanDirection.LeftToRight;
mpBarcode.HatchPattern = BarcodeHatchPattern.CreateLineHatchPattern(0.5f, true, false);
vectorImage.AddBarcode(mpBarcode);
scanDocument.Scripts.Add(new ScanningScriptChunk("defaultScript", "ScanAll()"));
try
{
scanDocument.StartScanning();
}
catch
{
}
}